home *** CD-ROM | disk | FTP | other *** search
/ Delphi Magazine Collection 2001 / Delphi Magazine Collection 20001 (2001).iso / Bonus / Plasmatech / ptscp_eval.exe / %MAINDIR% / EvalC3 / UPTShellControls.hpp < prev    next >
Encoding:
C/C++ Source or Header  |  2001-08-31  |  37.0 KB  |  899 lines

  1. // Borland C++ Builder
  2. // Copyright (c) 1995, 1998 by Borland International
  3. // All rights reserved
  4.  
  5. // (DO NOT EDIT: machine generated header) 'UPTShellControls.pas' rev: 3.00
  6.  
  7. #ifndef UPTShellControlsHPP
  8. #define UPTShellControlsHPP
  9. #include <UPTImageCombo.hpp>
  10. #include <UPTShellUtils.hpp>
  11. #include <UPTTreeList.hpp>
  12. #include <UPTShell95.hpp>
  13. #include <OLE2.hpp>
  14. #include <Menus.hpp>
  15. #include <ExtCtrls.hpp>
  16. #include <ComCtrls.hpp>
  17. #include <Commctrl.hpp>
  18. #include <StdCtrls.hpp>
  19. #include <ShellAPI.hpp>
  20. #include <Dialogs.hpp>
  21. #include <Forms.hpp>
  22. #include <Controls.hpp>
  23. #include <Graphics.hpp>
  24. #include <Classes.hpp>
  25. #include <SysUtils.hpp>
  26. #include <Messages.hpp>
  27. #include <Windows.hpp>
  28. #include <SysInit.hpp>
  29. #include <System.hpp>
  30.  
  31. //-- user supplied -----------------------------------------------------------
  32.  
  33. namespace Uptshellcontrols
  34. {
  35. //-- type declarations -------------------------------------------------------
  36. enum TPTShellTreeOption { ptstoAutoFill, ptstoVirtualFolders, ptstoDesignInteractive, ptstoDefaultKeyHandling, 
  37.     ptstoContextMenus, ptstoDynamicRefresh, ptstoIncludeNonFolders, ptstoOleDrag, ptstoOleDrop, ptstoShowHidden 
  38.     };
  39.  
  40. typedef Set<TPTShellTreeOption, ptstoAutoFill, ptstoShowHidden>  TPTShellTreeOptions;
  41.  
  42. enum TPTShellListOption { ptsloAutoFill, ptsloNonFilesystemAncestors, ptsloDesignInteractive, ptsloDefaultKeyHandling, 
  43.     ptsloContextMenus, ptsloDontChangeFolder, ptsloDontGoBelowBase, ptsloDynamicRefresh, ptsloHideFoldersWhenLinkedToTree, 
  44.     ptsloOleDrag, ptsloOleDrop, ptsloFolderContextMenu, ptsloShowHidden };
  45.  
  46. typedef Set<TPTShellListOption, ptsloAutoFill, ptsloShowHidden>  TPTShellListOptions;
  47.  
  48. enum TPTShellComboOption { ptscoAutofill, ptscoNonFilesystemAncestors };
  49.  
  50. typedef Set<TPTShellComboOption, ptscoAutofill, ptscoNonFilesystemAncestors>  TPTShellComboOptions;
  51.  
  52. typedef void __fastcall (__closure *TPTShAddItemEvent)(System::TObject* aSender, Uptshell95::IShellFolder* 
  53.     aParentIShf, Uptshell95::PItemIDList aParentAbsIdList, Uptshell95::PItemIDList aItemRelIdList, int 
  54.     aAttribs, BOOL &afAllowAdd);
  55.  
  56. typedef void __fastcall (__closure *TPTShTreeInsertItemEvent)(System::TObject* aSender, Comctrls::TTreeNode* 
  57.     aNode);
  58.  
  59. class DELPHICLASS TPTShTreeData;
  60. typedef void __fastcall (__closure *TPTShTreeDeleteItemEvent)(System::TObject* aSender, Comctrls::TTreeNode* 
  61.     aNode, TPTShTreeData* aShTreeData);
  62.  
  63. class DELPHICLASS TPTShListData;
  64. typedef void __fastcall (__closure *TPTShListDeleteItemEvent)(System::TObject* aSender, Comctrls::TListItem* 
  65.     aNode, TPTShListData* aShListData);
  66.  
  67. class DELPHICLASS TPTShComboData;
  68. typedef void __fastcall (__closure *TPTShComboDeleteItemEvent)(System::TObject* aSender, int aItem, 
  69.     TPTShComboData* aShComboData);
  70.  
  71. typedef void __fastcall (__closure *TPTShDblClickOpenEvent)(System::TObject* aSender, bool &afHandled
  72.     );
  73.  
  74. typedef void __fastcall (__closure *TPTShPopupHintEvent)(System::TObject* aSender, const System::AnsiString 
  75.     hint);
  76.  
  77. typedef void __fastcall (__closure *TPTShTvCustomDrawEvent)(System::TObject* aSender, Upttreelist::TPTCustomDraw* 
  78.     aCD, Comctrls::TTreeNode* aNode, TPTShTreeData* aData);
  79.  
  80. typedef void __fastcall (__closure *TPTShLvCustomDrawEvent)(System::TObject* aSender, Upttreelist::TPTCustomDraw* 
  81.     aCD, Comctrls::TListItem* aItem, TPTShListData* aData);
  82.  
  83. enum TPTShellLocator_Which { usePidl, useCSIDL };
  84.  
  85. class DELPHICLASS TPTShellLocator;
  86. class PASCALIMPLEMENTATION TPTShellLocator : public Classes::TPersistent 
  87. {
  88.     typedef Classes::TPersistent inherited;
  89.     
  90. protected:
  91.     TPTShellLocator_Which mWhich;
  92.     Uptshell95::TItemIDList *mIdList;
  93.     TCSIDL mCSIDL;
  94.     Classes::TNotifyEvent mOnChange;
  95.     DYNAMIC void __fastcall Changed(void);
  96.     System::AnsiString __fastcall GetPathName(void);
  97.     Uptshell95::PItemIDList __fastcall GetIdList(void);
  98.     Uptshellutils::TCSIDL __fastcall GetCSIDL(void);
  99.     void __fastcall SetIdList(Uptshell95::PItemIDList aValue);
  100.     void __fastcall SetPathName(System::AnsiString aValue);
  101.     void __fastcall SetCSIDL(Uptshellutils::TCSIDL aValue);
  102.     virtual void __fastcall DefineProperties(Classes::TFiler* filer);
  103.     void __fastcall ReadData(Classes::TStream* stream);
  104.     void __fastcall WriteData(Classes::TStream* stream);
  105.     
  106. public:
  107.     __fastcall virtual ~TPTShellLocator(void);
  108.     virtual void __fastcall Assign(Classes::TPersistent* source);
  109.     bool __fastcall IsEqual(TPTShellLocator* aValue);
  110.     void __fastcall Clear(void);
  111.     __property Uptshell95::PItemIDList IdList = {read=GetIdList, write=SetIdList};
  112.     __property System::AnsiString PathName = {read=GetPathName, write=SetPathName};
  113.     __property Uptshellutils::TCSIDL CSIDL = {read=GetCSIDL, write=SetCSIDL, nodefault};
  114.     __property Classes::TNotifyEvent OnChange = {read=mOnChange, write=mOnChange};
  115. public:
  116.     /* TObject.Create */ __fastcall TPTShellLocator(void) : Classes::TPersistent() { }
  117.     
  118. };
  119.  
  120. class DELPHICLASS TPTCustomShellTree;
  121. class DELPHICLASS TPTCustomShellList;
  122. enum TPTCustomShellList_LCS { lcsNone, lcsShellDetails, lcsDefault };
  123.  
  124. class DELPHICLASS TPTCustomShellCombo;
  125. class PASCALIMPLEMENTATION TPTCustomShellCombo : public Uptimagecombo::TPTCustomImageCombo 
  126. {
  127.     typedef Uptimagecombo::TPTCustomImageCombo inherited;
  128.     
  129. private:
  130.     int mIgnoreChanges;
  131.     TPTCustomShellTree* mShellTree;
  132.     TPTCustomShellList* mShellList;
  133.     TPTShellLocator* mSelectedFolder;
  134.     TPTShellComboOptions mOptions;
  135.     HIDESBASE MESSAGE void __fastcall CMDesignHitTest(Messages::TWMMouse &aMsg);
  136.     TPTShellLocator* __fastcall GetSelectedFolder(void);
  137.     TPTShComboData* __fastcall GetShComboData(int index);
  138.     void __fastcall SetSelectedFolder(TPTShellLocator* aValue);
  139.     void __fastcall SetShellList(TPTCustomShellList* aValue);
  140.     void __fastcall SetShellTree(TPTCustomShellTree* aValue);
  141.     
  142. protected:
  143.     virtual BOOL __fastcall CanAdd(Uptshell95::IShellFolder* aParentIShf, Uptshell95::PItemIDList aParentAbsPidl
  144.         , Uptshell95::PItemIDList aItemRelPidl, int attribs);
  145.     DYNAMIC void __fastcall SelEndOk(void);
  146.     virtual void __fastcall CreateWnd(void);
  147.     virtual void __fastcall DestroyWnd(void);
  148.     virtual void __fastcall Loaded(void);
  149.     virtual void __fastcall DeleteItem(void * aItem);
  150.     virtual void __fastcall GetItemData(Uptimagecombo::TPTImageComboItem* aItem);
  151.     virtual void __fastcall SelectedFolderChanged(System::TObject* aSender);
  152.     virtual void __fastcall TreeChanged(Comctrls::TTreeNode* aTreeNode);
  153.     virtual void __fastcall FillCombo(Uptshell95::IShellFolder* aIShf, Uptshell95::PItemIDList aBasePidl
  154.         , int aIndent, Uptshellutils::TPTIdListArray* aSelectedItem);
  155.     __property TPTCustomShellTree* ShellTree = {read=mShellTree, write=SetShellTree};
  156.     __property TPTCustomShellList* ShellList = {read=mShellList, write=SetShellList};
  157.     __property IndentPixels ;
  158.     __property TPTShellComboOptions Options = {read=mOptions, write=mOptions, default=3};
  159.     __property TPTShellLocator* SelectedFolder = {read=GetSelectedFolder, write=SetSelectedFolder};
  160.     __property TPTShComboData* ShComboData[int index] = {read=GetShComboData};
  161.     __property Items  = {stored=false};
  162.     
  163. public:
  164.     __fastcall virtual TPTCustomShellCombo(Classes::TComponent* aOwner);
  165.     __fastcall virtual ~TPTCustomShellCombo(void);
  166.     void __fastcall FillItems(void);
  167.     void __fastcall GoUp(int aLevels);
  168.     void __fastcall Synchronize(bool afApplyToGroup);
  169. public:
  170.     /* TWinControl.CreateParented */ __fastcall TPTCustomShellCombo(HWND ParentWindow) : Uptimagecombo::
  171.         TPTCustomImageCombo(ParentWindow) { }
  172.     
  173. };
  174.  
  175. class PASCALIMPLEMENTATION TPTCustomShellList : public Upttreelist::TPTCustomListView 
  176. {
  177.     typedef Upttreelist::TPTCustomListView inherited;
  178.     
  179. private:
  180.     TPTCustomShellList_LCS mLastColState;
  181.     bool mLastFolderWasDir;
  182.     TPTShPopupHintEvent mOnPopupHintProc;
  183.     Uptshell95::IShellFolder* mIShf;
  184.     Uptshell95::TItemIDList *mIShfPidl;
  185.     bool mfIShellDetailsValid;
  186.     Uptshell95::IShellDetails* mIShellDetails;
  187.     TPTShellLocator* mFolder;
  188.     TPTShellListOptions mOptions;
  189.     TPTShAddItemEvent mOnAddItemProc;
  190.     TPTShListDeleteItemEvent mOnDeleteItemProc;
  191.     TPTShDblClickOpenEvent mOnDblClickOpenProc;
  192.     TPTShLvCustomDrawEvent mOnCustomDrawShProc;
  193.     TPTShLvCustomDrawEvent mOnCustomDrawShExProc;
  194.     Classes::TNotifyEvent mOnFillComplete;
  195.     Classes::TNotifyEvent mOnFillStart;
  196.     Classes::TNotifyEvent mOnFolderChanged;
  197.     System::AnsiString mFileFilter;
  198.     void *mFilterLookupTable;
  199.     Classes::TStringList* mFilterExtensions;
  200.     Extctrls::TTimer* mTimer;
  201.     TPTCustomShellTree* mShellTree;
  202.     TPTCustomShellCombo* mShellCombo;
  203.     Uptshell95::IContextMenu* mActiveIContextMenu;
  204.     int mSortColumn;
  205.     int mIgnoreChanges;
  206.     bool mfIgnoreNextChangeNotify;
  207.     void *mChangeHandlerThread;
  208.     System::AnsiString mDeferredEditName;
  209.     bool mfSkipRButtonUp;
  210.     bool mfDeferRefresh;
  211.     bool mfRefreshDeferred;
  212.     TPTShListData* mCurrentItemData;
  213.     int mCurrentItemFlags;
  214.     Uptshell95::IShellDetails* mCurrentItemIShd;
  215.     int mLastAutoScrollTick;
  216.     bool mfLoaded;
  217.     bool mfInCreateWnd;
  218.     bool mfSortColumnAssigned;
  219.     bool mfDeletingItems;
  220.     IDataObject* mIDataObject;
  221.     void __fastcall OleBeginDrag(Controls::TMouseButton aButton);
  222.     
  223. protected:
  224.     IDropTarget* mIDropTarget;
  225.     IDataObject* mILastDropDataObject;
  226.     int mInitialDropKeyState;
  227.     virtual int __fastcall OnDropTarget_DragEnter(const IDataObject* dataObj, int grfKeyState, const tagPOINT 
  228.         &pt, int &dwEffect);
  229.     virtual int __fastcall OnDropTarget_DragOver(int grfKeyState, const tagPOINT &pt, int &dwEffect);
  230.     virtual int __fastcall OnDropTarget_DragLeave(void);
  231.     virtual int __fastcall OnDropTarget_Drop(const IDataObject* dataObj, int grfKeyState, const tagPOINT 
  232.         &pt, int &dwEffect);
  233.     
  234. private:
  235.     void __fastcall InitColumns(Uptshell95::IShellDetails* ishd);
  236.     void __fastcall InitImageLists(void);
  237.     bool __fastcall IsFolderStored(void);
  238.     Uptshell95::IShellDetails* __fastcall GetCurrentFolderIShellDetails(void);
  239.     void __fastcall HandleOnFolderChanged(System::TObject* aSender);
  240.     TPTShListData* __fastcall GetSelectedItem(void);
  241.     TPTShListData* __fastcall GetShListData(int idx);
  242.     void __fastcall SetFileFilter(const System::AnsiString aValue);
  243.     void __fastcall SetFolder(TPTShellLocator* aValue);
  244.     void __fastcall SetShellTree(TPTCustomShellTree* aValue);
  245.     void __fastcall SetShellCombo(TPTCustomShellCombo* aValue);
  246.     void __fastcall SetSortColumn(int aValue);
  247.     void __fastcall SetOptions(TPTShellListOptions aValue);
  248.     void __fastcall TimerElapsed(System::TObject* sender);
  249.     MESSAGE void __fastcall AMChangeNotify(Messages::TMessage &aMsg);
  250.     MESSAGE void __fastcall AMDeferredEdit(Messages::TMessage &aMsg);
  251.     MESSAGE void __fastcall AMDeferredFill(Messages::TMessage &aMsg);
  252.     HIDESBASE MESSAGE void __fastcall CMDesignHitTest(Messages::TWMMouse &aMsg);
  253.     MESSAGE void __fastcall CMWantSpecialKey(Messages::TWMKey &aMsg);
  254.     HIDESBASE MESSAGE void __fastcall CNNotify(Messages::TWMNotify &aMsg);
  255.     MESSAGE void __fastcall WMMenuChar(Messages::TWMMenuChar &aMsg);
  256.     HIDESBASE MESSAGE void __fastcall WMDrawItem(Messages::TWMDrawItem &aMsg);
  257.     HIDESBASE MESSAGE void __fastcall WMDestroy(Messages::TWMNoParams &aMsg);
  258.     HIDESBASE MESSAGE void __fastcall WMNCDestroy(Messages::TWMNoParams &aMsg);
  259.     HIDESBASE MESSAGE void __fastcall WMNCHitTest(Messages::TWMNCHitTest &aMsg);
  260.     HIDESBASE MESSAGE void __fastcall WMMeasureItem(Messages::TWMMeasureItem &aMsg);
  261.     MESSAGE void __fastcall WMMenuSelect(Messages::TWMMenuSelect &aMsg);
  262.     HIDESBASE MESSAGE void __fastcall WMRButtonUp(Messages::TWMMouse &aMsg);
  263.     MESSAGE void __fastcall WMInitMenuPopup(Messages::TWMInitMenuPopup &aMsg);
  264.     HIDESBASE MESSAGE void __fastcall WMWindowPosChanged(Messages::TWMWindowPosMsg &aMsg);
  265.     MESSAGE void __fastcall WMGetIShellBrowser(Messages::TMessage &aMsg);
  266.     
  267. protected:
  268.     bool __fastcall ShouldInclude(Uptshell95::PItemIDList baseidlist, Uptshell95::PItemIDList relidlist
  269.         , int &attrib);
  270.     int __fastcall AddNewShellItem(Uptshell95::PItemIDList aAbsIdList, Uptshell95::PItemIDList aRelIdList
  271.         );
  272.     virtual BOOL __fastcall CanAdd(Uptshell95::IShellFolder* parentIShf, Uptshell95::PItemIDList parentAbsPidl
  273.         , Uptshell95::PItemIDList itemRelPidl, int itemAttributes);
  274.     DYNAMIC bool __fastcall CanEdit(Comctrls::TListItem* aItem);
  275.     DYNAMIC bool __fastcall DblClickOpen(void);
  276.     virtual void __fastcall DeviceChangeDetected(System::TObject* ASender, Messages::TMessage &AMessage
  277.         );
  278.     DYNAMIC void __fastcall Edit(const tagLVITEMA &Item);
  279.     virtual void __fastcall FillList(Uptshell95::IShellFolder* ishf, Uptshell95::PItemIDList basepidl);
  280.         
  281.     DYNAMIC void __fastcall FillComplete(void);
  282.     DYNAMIC void __fastcall FillStart(void);
  283.     DYNAMIC void __fastcall FolderChanged(void);
  284.     virtual void __fastcall Loaded(void);
  285.     virtual void __fastcall Notification(Classes::TComponent* aComponent, Classes::TOperation aOperation
  286.         );
  287.     virtual void __fastcall CreateWnd(void);
  288.     virtual void __fastcall DestroyWnd(void);
  289.     void __fastcall TreeChanged(Comctrls::TTreeNode* aTreeNode);
  290.     DYNAMIC void __fastcall Delete(Comctrls::TListItem* item);
  291.     DYNAMIC void __fastcall ColClick(Comctrls::TListColumn* Column);
  292.     DYNAMIC int __fastcall GetUIObjectForAllSelected(const GUID &riid, void * &interfaceOut);
  293.     DYNAMIC int __fastcall GetUIObjectForItem(Comctrls::TListItem* aItem, const GUID &riid, void * &interfaceOut
  294.         );
  295.     DYNAMIC void __fastcall KeyDown(Word &key, Classes::TShiftState aShiftState);
  296.     DYNAMIC void __fastcall KeyPress(char &key);
  297.     DYNAMIC void __fastcall MouseDown(Controls::TMouseButton aButton, Classes::TShiftState aShift, int 
  298.         x, int y);
  299.     DYNAMIC void __fastcall ItemContextMenu(Comctrls::TListItem* aItem, tagPOINT &aPos, Menus::TPopupMenu* 
  300.         &aMenu);
  301.     bool __fastcall ItemHasData(Comctrls::TListItem* aItem);
  302.     DYNAMIC void __fastcall InsertItem(Comctrls::TListItem* Item);
  303.     virtual Upttreelist::TPTCustomDraw* __fastcall PTCustomDraw(const Upttreelist::TNMCustomDraw &aNMHDR
  304.         , int &aResult);
  305.     DYNAMIC void __fastcall PTCustomDrawSh(Upttreelist::TPTCustomDraw* aCD, Comctrls::TListItem* aItem, 
  306.         TPTShListData* aData);
  307.     DYNAMIC void __fastcall InstallChangeHandler(void);
  308.     virtual void __fastcall FilterPreApply(void);
  309.     virtual bool __fastcall FilterApply(const System::AnsiString aFilename, int aAttrib);
  310.     virtual void __fastcall FilterPostApply(void);
  311.     bool __fastcall IsFolderNetworkShare(void);
  312.     __property Columns  = {stored=false};
  313.     __property Items  = {stored=false};
  314.     __property AllocBy  = {stored=false, default=0};
  315.     __property TPTShListData* SelectedItem = {read=GetSelectedItem};
  316.     __property TPTShListData* ShListData[int idx] = {read=GetShListData};
  317.     __property int SortColumn = {read=mSortColumn, write=SetSortColumn, nodefault};
  318.     __property Uptshell95::IShellFolder* _IShellFolder = {read=mIShf};
  319.     __property TPTShellListOptions Options = {read=mOptions, write=SetOptions, default=7835};
  320.     __property TPTShellLocator* Folder = {read=mFolder, write=SetFolder, stored=IsFolderStored};
  321.     __property System::AnsiString FileFilter = {read=mFileFilter, write=SetFileFilter};
  322.     __property TPTShAddItemEvent OnAddItem = {read=mOnAddItemProc, write=mOnAddItemProc};
  323.     __property TPTShListDeleteItemEvent OnDeleteItem = {read=mOnDeleteItemProc, write=mOnDeleteItemProc
  324.         };
  325.     __property TPTShPopupHintEvent OnPopupHint = {read=mOnPopupHintProc, write=mOnPopupHintProc};
  326.     __property TPTShDblClickOpenEvent OnDblClickOpen = {read=mOnDblClickOpenProc, write=mOnDblClickOpenProc
  327.         };
  328.     __property TPTShLvCustomDrawEvent OnCustomDrawSh = {read=mOnCustomDrawShProc, write=mOnCustomDrawShProc
  329.         };
  330.     __property TPTShLvCustomDrawEvent OnCustomDrawShEx = {read=mOnCustomDrawShExProc, write=mOnCustomDrawShExProc
  331.         };
  332.     __property Classes::TNotifyEvent OnFillComplete = {read=mOnFillComplete, write=mOnFillComplete};
  333.     __property Classes::TNotifyEvent OnFillStart = {read=mOnFillStart, write=mOnFillStart};
  334.     __property Classes::TNotifyEvent OnFolderChanged = {read=mOnFolderChanged, write=mOnFolderChanged};
  335.         
  336.     
  337. public:
  338.     __fastcall virtual TPTCustomShellList(Classes::TComponent* aOwner);
  339.     __fastcall virtual ~TPTCustomShellList(void);
  340.     bool __fastcall CreateNewFolder(bool afEditNow);
  341.     void __fastcall DoCommandForItem(Comctrls::TListItem* aItem, char * cmd);
  342.     void __fastcall DoCommandForAllSelected(char * cmd);
  343.     void __fastcall DoCommandForFolder(char * cmd);
  344.     void __fastcall FillItems(void);
  345.     void __fastcall GoUp(int aLevels);
  346.     TPTShListData* __fastcall GetDataFromItem(Comctrls::TListItem* item);
  347.     void __fastcall OpenItem(Comctrls::TListItem* aItem);
  348.     void __fastcall OpenSelectedItems(void);
  349.     void __fastcall ProcessMenu(Comctrls::TListItem* aItem, const tagPOINT &at);
  350.     void __fastcall ProcessMenuForAllSelected(const tagPOINT &at);
  351.     void __fastcall ProcessSendTo(int idx);
  352.     void __fastcall RefreshItems(void);
  353.     int __fastcall GetDragDropAttributesForAllSelected(void);
  354.     int __fastcall GetDragDropAttributesForItem(Comctrls::TListItem* item);
  355.     void __fastcall SelectAll(void);
  356.     int __fastcall ShellSelCount(void);
  357.     void __fastcall SortList(void);
  358.     void __fastcall Synchronize(bool afApplyToGroup);
  359. public:
  360.     /* TWinControl.CreateParented */ __fastcall TPTCustomShellList(HWND ParentWindow) : Upttreelist::TPTCustomListView(
  361.         ParentWindow) { }
  362.     
  363. };
  364.  
  365. class PASCALIMPLEMENTATION TPTCustomShellTree : public Upttreelist::TPTCustomTreeView 
  366. {
  367.     typedef Upttreelist::TPTCustomTreeView inherited;
  368.     
  369. private:
  370.     TPTShellLocator* mBaseFolder;
  371.     TPTShellLocator* mSelectedFolder;
  372.     Extctrls::TTimer* mTimer;
  373.     TPTCustomShellList* mShellList;
  374.     TPTShellTreeOptions mOptions;
  375.     TPTShAddItemEvent mOnAddItemProc;
  376.     TPTShTreeDeleteItemEvent mOnDeleteItemProc;
  377.     TPTShTreeInsertItemEvent mOnInsertItemProc;
  378.     TPTShPopupHintEvent mOnPopupHintProc;
  379.     TPTShTvCustomDrawEvent mOnCustomDrawShProc;
  380.     TPTShTvCustomDrawEvent mOnCustomDrawShExProc;
  381.     Classes::TNotifyEvent mOnFillCompleteProc;
  382.     Classes::TNotifyEvent mOnFillStartProc;
  383.     TPTCustomShellCombo* mShellCombo;
  384.     Uptshell95::IContextMenu* mActiveIContextMenu;
  385.     BOOL mfQuickSelect;
  386.     int mIgnoreChanges;
  387.     BOOL mfEatExpand;
  388.     bool mfIgnoreNextChangeNotify;
  389.     void *mChangeHandlerThread;
  390.     bool mfDeferRefresh;
  391.     bool mfRefreshDeferred;
  392.     Comctrls::TTreeNode* mDragNode;
  393.     int mLastAutoScrollTick;
  394.     Comctrls::TTreeNode* mLastNode;
  395.     bool mfLoaded;
  396.     bool mfDeletingNodes;
  397.     IDataObject* mIDataObject;
  398.     void __fastcall OleBeginDrag(Controls::TMouseButton aButton);
  399.     
  400. protected:
  401.     IDropTarget* mIDropTarget;
  402.     IDataObject* mILastDropDataObject;
  403.     int mInitialDropKeyState;
  404.     virtual int __fastcall OnDropTarget_DragEnter(const IDataObject* dataObj, int grfKeyState, const tagPOINT 
  405.         &pt, int &dwEffect);
  406.     virtual int __fastcall OnDropTarget_DragOver(int grfKeyState, const tagPOINT &pt, int &dwEffect);
  407.     virtual int __fastcall OnDropTarget_DragLeave(void);
  408.     virtual int __fastcall OnDropTarget_Drop(const IDataObject* dataObj, int grfKeyState, const tagPOINT 
  409.         &pt, int &dwEffect);
  410.     
  411. private:
  412.     void __fastcall InitImageList(void);
  413.     void __fastcall BaseFolderChanged(System::TObject* sender);
  414.     void __fastcall SelectedFolderChanged(System::TObject* sender);
  415.     void __fastcall TimerElapsed(System::TObject* sender);
  416.     TPTShTreeData* __fastcall GetSelectedItem(void);
  417.     System::AnsiString __fastcall GetSelectedPathName(void);
  418.     TPTShTreeData* __fastcall GetShTreeData(int idx);
  419.     void __fastcall SetBaseFolder(TPTShellLocator* aValue);
  420.     void __fastcall SetShellList(TPTCustomShellList* aValue);
  421.     void __fastcall SetOptions(TPTShellTreeOptions aValue);
  422.     void __fastcall SetSelectedFolder(TPTShellLocator* aValue);
  423.     void __fastcall DoSetSelectedIdList(Uptshell95::PItemIDList aValue);
  424.     void __fastcall SetShellCombo(TPTCustomShellCombo* aValue);
  425.     MESSAGE void __fastcall AMChangeNotify(Messages::TMessage &aMsg);
  426.     MESSAGE void __fastcall AMDeferredFill(Messages::TMessage &aMsg);
  427.     HIDESBASE MESSAGE void __fastcall CMDesignHitTest(Messages::TWMMouse &aMsg);
  428.     MESSAGE void __fastcall CMWantSpecialKey(Messages::TWMKey &aMsg);
  429.     HIDESBASE MESSAGE void __fastcall CNNotify(Messages::TWMNotify &aMsg);
  430.     MESSAGE void __fastcall TVMDeleteItem(Messages::TMessage &aMsg);
  431.     MESSAGE void __fastcall WMMenuChar(Messages::TWMMenuChar &aMsg);
  432.     HIDESBASE MESSAGE void __fastcall WMDrawItem(Messages::TWMDrawItem &aMsg);
  433.     HIDESBASE MESSAGE void __fastcall WMNCDestroy(Messages::TWMNoParams &aMsg);
  434.     HIDESBASE MESSAGE void __fastcall WMNCHitTest(Messages::TWMNCHitTest &aMsg);
  435.     HIDESBASE MESSAGE void __fastcall WMMeasureItem(Messages::TWMMeasureItem &aMsg);
  436.     MESSAGE void __fastcall WMMenuSelect(Messages::TWMMenuSelect &aMsg);
  437.     MESSAGE void __fastcall WMInitMenuPopup(Messages::TWMInitMenuPopup &aMsg);
  438.     HIDESBASE MESSAGE void __fastcall WMWindowPosChanged(Messages::TWMWindowPosMsg &aMsg);
  439.     HIDESBASE MESSAGE void __fastcall WMPaint(Messages::TWMPaint &aMsg);
  440.     
  441. protected:
  442.     void __fastcall SetSelectedPathName(System::AnsiString aValue);
  443.     int __fastcall AddNewShellNode(Uptshell95::IShellFolder* aParent, Uptshell95::PItemIDList aParentAbsIdList
  444.         , Comctrls::TTreeNode* aParentNode, Uptshell95::PItemIDList aRelIdList);
  445.     virtual BOOL __fastcall CanAdd(Uptshell95::IShellFolder* aParentIShf, Uptshell95::PItemIDList aParentAbsPidl
  446.         , Uptshell95::PItemIDList aItemRelPidl, int attribs);
  447.     DYNAMIC bool __fastcall CanExpand(Comctrls::TTreeNode* aNode);
  448.     DYNAMIC bool __fastcall CanEdit(Comctrls::TTreeNode* Node);
  449.     DYNAMIC void __fastcall Change(Comctrls::TTreeNode* Node);
  450.     virtual void __fastcall DeviceChangeDetected(System::TObject* ASender, Messages::TMessage &AMessage
  451.         );
  452.     virtual Upttreelist::TPTCustomDraw* __fastcall PTCustomDraw(const Upttreelist::TNMCustomDraw &aNMHDR
  453.         , int &aResult);
  454.     DYNAMIC void __fastcall PTCustomDrawSh(Upttreelist::TPTCustomDraw* aCD, Comctrls::TTreeNode* aNode, 
  455.         TPTShTreeData* aData);
  456.     DYNAMIC void __fastcall DoOnInsertItem(Comctrls::TTreeNode* aNode);
  457.     DYNAMIC void __fastcall NodeContextMenu(Comctrls::TTreeNode* aNode, tagPOINT &aPos, Menus::TPopupMenu* 
  458.         &aMenu);
  459.     bool __fastcall NodeHasData(Comctrls::TTreeNode* aNode);
  460.     DYNAMIC void __fastcall Delete(Comctrls::TTreeNode* aNode);
  461.     DYNAMIC void __fastcall ExpandNode(Comctrls::TTreeNode* aNode);
  462.     DYNAMIC void __fastcall Edit(const tagTVITEMA &aItem);
  463.     virtual void __fastcall FillTree(Uptshell95::IShellFolder* ishf, Comctrls::TTreeNode* aBaseNode);
  464.     DYNAMIC void __fastcall FillComplete(void);
  465.     DYNAMIC void __fastcall FillStart(void);
  466.     Comctrls::TTreeNode* __fastcall GetFirstRootLevelShellNode(void);
  467.     virtual void __fastcall GetImageIndex(Comctrls::TTreeNode* aNode);
  468.     virtual void __fastcall GetSelectedIndex(Comctrls::TTreeNode* aNode);
  469.     virtual void __fastcall Loaded(void);
  470.     virtual void __fastcall Notification(Classes::TComponent* aComponent, Classes::TOperation aOperation
  471.         );
  472.     virtual void __fastcall CreateParams(Controls::TCreateParams &p);
  473.     virtual void __fastcall CreateWnd(void);
  474.     virtual void __fastcall DestroyWnd(void);
  475.     DYNAMIC void __fastcall KeyDown(Word &key, Classes::TShiftState aShiftState);
  476.     DYNAMIC void __fastcall ProcessSendTo(Comctrls::TTreeNode* aItem, int idx);
  477.     DYNAMIC void __fastcall InstallChangeHandler(const System::AnsiString aPathname);
  478.     void __fastcall InstallChangeHandlersForAllLocalDrives(void);
  479.     __property TPTShTreeData* SelectedItem = {read=GetSelectedItem};
  480.     __property TPTShellLocator* SelectedFolder = {read=mSelectedFolder, write=SetSelectedFolder};
  481.     __property System::AnsiString SelectedPathName = {read=GetSelectedPathName, write=SetSelectedPathName
  482.         };
  483.     __property TPTShTreeData* ShTreeData[int idx] = {read=GetShTreeData};
  484.     __property Items  = {stored=false};
  485.     __property TPTShellLocator* BaseFolder = {read=mBaseFolder, write=SetBaseFolder};
  486.     __property TPTCustomShellList* ShellList = {read=mShellList, write=SetShellList};
  487.     __property TPTShellTreeOptions Options = {read=mOptions, write=SetOptions, default=955};
  488.     __property TPTShAddItemEvent OnAddItem = {read=mOnAddItemProc, write=mOnAddItemProc};
  489.     __property TPTShTreeDeleteItemEvent OnDeleteItem = {read=mOnDeleteItemProc, write=mOnDeleteItemProc
  490.         };
  491.     __property TPTShTreeInsertItemEvent OnInsertItem = {read=mOnInsertItemProc, write=mOnInsertItemProc
  492.         };
  493.     __property TPTShPopupHintEvent OnPopupHint = {read=mOnPopupHintProc, write=mOnPopupHintProc};
  494.     __property Classes::TNotifyEvent OnFillComplete = {read=mOnFillCompleteProc, write=mOnFillCompleteProc
  495.         };
  496.     __property Classes::TNotifyEvent OnFillStart = {read=mOnFillStartProc, write=mOnFillStartProc};
  497.     __property TPTShTvCustomDrawEvent OnCustomDrawSh = {read=mOnCustomDrawShProc, write=mOnCustomDrawShProc
  498.         };
  499.     __property TPTShTvCustomDrawEvent OnCustomDrawShEx = {read=mOnCustomDrawShExProc, write=mOnCustomDrawShExProc
  500.         };
  501.     
  502. public:
  503.     __fastcall virtual TPTCustomShellTree(Classes::TComponent* aOwner);
  504.     __fastcall virtual ~TPTCustomShellTree(void);
  505.     void __fastcall FillItems(void);
  506.     void __fastcall RefreshNodes(void);
  507.     TPTShTreeData* __fastcall GetDataFromNode(Comctrls::TTreeNode* node);
  508.     void __fastcall GoUp(int aLevels);
  509.     bool __fastcall CreateNewFolder(bool afEditNow);
  510.     int __fastcall DoCommandForNode(Comctrls::TTreeNode* aNode, char * aCmd);
  511.     Comctrls::TTreeNode* __fastcall FindNodeWithIdList(Comctrls::TTreeNode* baseNode, Uptshell95::PItemIDList 
  512.         pidl);
  513.     DYNAMIC void __fastcall ProcessMenu(Comctrls::TTreeNode* aItem, const tagPOINT &at);
  514.     void __fastcall SortNode(Comctrls::TTreeNode* aTreeNode);
  515.     void __fastcall Synchronize(bool afApplyToGroup);
  516.     int __fastcall GetDragDropAttributesForNode(Comctrls::TTreeNode* node);
  517. public:
  518.     /* TWinControl.CreateParented */ __fastcall TPTCustomShellTree(HWND ParentWindow) : Upttreelist::TPTCustomTreeView(
  519.         ParentWindow) { }
  520.     
  521. };
  522.  
  523. class DELPHICLASS TPTShellTree;
  524. class PASCALIMPLEMENTATION TPTShellTree : public Uptshellcontrols::TPTCustomShellTree 
  525. {
  526.     typedef Uptshellcontrols::TPTCustomShellTree inherited;
  527.     
  528. public:
  529.     __property SelectedItem ;
  530.     __property SelectedFolder ;
  531.     __property SelectedPathName ;
  532.     __property ShTreeData ;
  533.     __property Items ;
  534.     
  535. __published:
  536.     __property BaseFolder ;
  537.     __property OnNodeContextMenu ;
  538.     __property ShellList ;
  539.     __property Options ;
  540.     __property OnAddItem ;
  541.     __property OnDeleteItem ;
  542.     __property OnInsertItem ;
  543.     __property OnPopupHint ;
  544.     __property OnCustomDrawSh ;
  545.     __property OnCustomDrawShEx ;
  546.     __property OnFillComplete ;
  547.     __property OnFillStart ;
  548.     __property ShowButtons ;
  549.     __property BorderStyle ;
  550.     __property DragCursor ;
  551.     __property ShowLines ;
  552.     __property ShowRoot ;
  553.     __property ReadOnly ;
  554.     __property DragMode ;
  555.     __property HideSelection ;
  556.     __property Indent ;
  557.     __property OnEditing ;
  558.     __property OnEdited ;
  559.     __property OnExpanding ;
  560.     __property OnExpanded ;
  561.     __property OnCollapsing ;
  562.     __property OnCollapsed ;
  563.     __property OnChanging ;
  564.     __property OnChange ;
  565.     __property OnDeletion ;
  566.     __property OnGetImageIndex ;
  567.     __property OnGetSelectedIndex ;
  568.     __property Align ;
  569.     __property Enabled ;
  570.     __property Font ;
  571.     __property Color ;
  572.     __property ParentColor ;
  573.     __property ParentCtl3D ;
  574.     __property ParentFont ;
  575.     __property Ctl3D ;
  576.     __property TabOrder ;
  577.     __property TabStop ;
  578.     __property Visible ;
  579.     __property OnClick ;
  580.     __property OnEnter ;
  581.     __property OnExit ;
  582.     __property OnDragDrop ;
  583.     __property OnDragOver ;
  584.     __property OnStartDrag ;
  585.     __property OnEndDrag ;
  586.     __property OnMouseDown ;
  587.     __property OnMouseMove ;
  588.     __property OnMouseUp ;
  589.     __property OnDblClick ;
  590.     __property OnKeyDown ;
  591.     __property OnKeyPress ;
  592.     __property OnKeyUp ;
  593.     __property PopupMenu ;
  594.     __property ParentShowHint ;
  595.     __property ShowHint ;
  596.     __property StateImages ;
  597.     __property RightClickSelect ;
  598. public:
  599.     /* TPTCustomShellTree.Create */ __fastcall virtual TPTShellTree(Classes::TComponent* aOwner) : Uptshellcontrols::
  600.         TPTCustomShellTree(aOwner) { }
  601.     /* TPTCustomShellTree.Destroy */ __fastcall virtual ~TPTShellTree(void) { }
  602.     
  603. public:
  604.     /* TWinControl.CreateParented */ __fastcall TPTShellTree(HWND ParentWindow) : Uptshellcontrols::TPTCustomShellTree(
  605.         ParentWindow) { }
  606.     
  607. };
  608.  
  609. class DELPHICLASS TPTShellList;
  610. class PASCALIMPLEMENTATION TPTShellList : public Uptshellcontrols::TPTCustomShellList 
  611. {
  612.     typedef Uptshellcontrols::TPTCustomShellList inherited;
  613.     
  614. public:
  615.     __property SelectedItem ;
  616.     __property ShListData ;
  617.     __property SortColumn ;
  618.     __property Columns ;
  619.     __property Items ;
  620.     __property _IShellFolder ;
  621.     __property HeaderCanvas ;
  622.     __property HeaderHandle ;
  623.     __property HeaderSortColumn ;
  624.     __property HeaderSortDirection ;
  625.     
  626. __published:
  627.     __property HeaderSortDisplayMode ;
  628.     __property OnItemContextMenu ;
  629.     __property Options ;
  630.     __property Folder ;
  631.     __property FileFilter ;
  632.     __property OnAddItem ;
  633.     __property OnDeleteItem ;
  634.     __property OnPopupHint ;
  635.     __property OnDblClickOpen ;
  636.     __property OnCustomDrawSh ;
  637.     __property OnCustomDrawShEx ;
  638.     __property OnFillComplete ;
  639.     __property OnFillStart ;
  640.     __property OnFolderChanged ;
  641.     __property Align ;
  642.     __property BorderStyle ;
  643.     __property Color ;
  644.     __property ColumnClick ;
  645.     __property OnClick ;
  646.     __property OnDblClick ;
  647.     __property Ctl3D ;
  648.     __property DragMode ;
  649.     __property Enabled ;
  650.     __property ReadOnly ;
  651.     __property Font ;
  652.     __property ParentColor ;
  653.     __property ParentCtl3D ;
  654.     __property ParentFont ;
  655.     __property HideSelection ;
  656.     __property IconOptions ;
  657.     __property MultiSelect ;
  658.     __property OnChange ;
  659.     __property OnChanging ;
  660.     __property OnColumnClick ;
  661.     __property OnDeletion ;
  662.     __property OnEdited ;
  663.     __property OnEditing ;
  664.     __property OnEnter ;
  665.     __property OnExit ;
  666.     __property OnInsert ;
  667.     __property OnDragDrop ;
  668.     __property OnDragOver ;
  669.     __property DragCursor ;
  670.     __property OnStartDrag ;
  671.     __property OnEndDrag ;
  672.     __property OnMouseDown ;
  673.     __property OnMouseMove ;
  674.     __property OnMouseUp ;
  675.     __property ParentShowHint ;
  676.     __property ShowHint ;
  677.     __property PopupMenu ;
  678.     __property ShowColumnHeaders ;
  679.     __property TabOrder ;
  680.     __property TabStop ;
  681.     __property ViewStyle ;
  682.     __property Visible ;
  683.     __property OnKeyDown ;
  684.     __property OnKeyPress ;
  685.     __property OnKeyUp ;
  686.     __property StateImages ;
  687.     __property OnCompare ;
  688.     __property Checkboxes ;
  689.     __property GridLines ;
  690.     __property HotTrack ;
  691.     __property RowSelect ;
  692. public:
  693.     /* TPTCustomShellList.Create */ __fastcall virtual TPTShellList(Classes::TComponent* aOwner) : Uptshellcontrols::
  694.         TPTCustomShellList(aOwner) { }
  695.     /* TPTCustomShellList.Destroy */ __fastcall virtual ~TPTShellList(void) { }
  696.     
  697. public:
  698.     /* TWinControl.CreateParented */ __fastcall TPTShellList(HWND ParentWindow) : Uptshellcontrols::TPTCustomShellList(
  699.         ParentWindow) { }
  700.     
  701. };
  702.  
  703. class DELPHICLASS TPTShellCombo;
  704. class PASCALIMPLEMENTATION TPTShellCombo : public Uptshellcontrols::TPTCustomShellCombo 
  705. {
  706.     typedef Uptshellcontrols::TPTCustomShellCombo inherited;
  707.     
  708. public:
  709.     __property SelectedFolder ;
  710.     __property ShComboData ;
  711.     
  712. __published:
  713.     __property ShellTree ;
  714.     __property ShellList ;
  715.     __property IndentPixels ;
  716.     __property Options ;
  717.     __property Color ;
  718.     __property Ctl3D ;
  719.     __property DragMode ;
  720.     __property DragCursor ;
  721.     __property DropDownCount ;
  722.     __property Enabled ;
  723.     __property Font ;
  724.     __property ParentColor ;
  725.     __property ParentCtl3D ;
  726.     __property ParentFont ;
  727.     __property ParentShowHint ;
  728.     __property PopupMenu ;
  729.     __property ShowHint ;
  730.     __property Sorted ;
  731.     __property TabOrder ;
  732.     __property TabStop ;
  733.     __property Visible ;
  734.     __property OnChange ;
  735.     __property OnClick ;
  736.     __property OnDblClick ;
  737.     __property OnDragDrop ;
  738.     __property OnDragOver ;
  739.     __property OnDrawItem ;
  740.     __property OnDropDown ;
  741.     __property OnEndDrag ;
  742.     __property OnEnter ;
  743.     __property OnExit ;
  744.     __property OnKeyDown ;
  745.     __property OnKeyPress ;
  746.     __property OnKeyUp ;
  747.     __property OnMeasureItem ;
  748.     __property OnStartDrag ;
  749.     __property OnDeleteItem ;
  750.     __property OnCloseUp ;
  751.     __property OnSelEndCancel ;
  752.     __property OnSelEndOk ;
  753. public:
  754.     /* TPTCustomShellCombo.Create */ __fastcall virtual TPTShellCombo(Classes::TComponent* aOwner) : Uptshellcontrols::
  755.         TPTCustomShellCombo(aOwner) { }
  756.     /* TPTCustomShellCombo.Destroy */ __fastcall virtual ~TPTShellCombo(void) { }
  757.     
  758. public:
  759.     /* TWinControl.CreateParented */ __fastcall TPTShellCombo(HWND ParentWindow) : Uptshellcontrols::TPTCustomShellCombo(
  760.         ParentWindow) { }
  761.     
  762. };
  763.  
  764. class PASCALIMPLEMENTATION TPTShTreeData : public System::TObject 
  765. {
  766.     typedef System::TObject inherited;
  767.     
  768. private:
  769.     TPTCustomShellTree* mOwner;
  770.     TPTShTreeData* mParent;
  771.     Uptshell95::TItemIDList *mRelPidl;
  772.     Uptshell95::TItemIDList *mAbsPidl;
  773.     Uptshell95::IShellFolder* mThisIshf;
  774.     Uptshell95::IShellFolder* mParentIShf;
  775.     void *mData;
  776.     Uptshell95::PItemIDList __fastcall GetAbsPidl(void);
  777.     bool __fastcall GetEditable(void);
  778.     System::AnsiString __fastcall GetPathName(void);
  779.     Uptshell95::IShellFolder* __fastcall GetParentIShf(void);
  780.     Uptshell95::IShellFolder* __fastcall GetThisIShf(void);
  781.     void __fastcall SetData(TPTShTreeData* aParent, Uptshell95::PItemIDList thisRelativePidl);
  782.     void __fastcall SetRelPidl(Uptshell95::PItemIDList newRelPidl);
  783.     
  784. public:
  785.     __fastcall TPTShTreeData(TPTCustomShellTree* aOwner);
  786.     __fastcall virtual ~TPTShTreeData(void);
  787.     int __fastcall GetIDropTarget(HWND h, IDropTarget* &idt);
  788.     bool __fastcall IsRootDir(void);
  789.     void __fastcall Flush(void);
  790.     __property TPTShTreeData* Parent = {read=mParent};
  791.     __property Uptshell95::IShellFolder* ParentIShf = {read=GetParentIShf};
  792.     __property Uptshell95::PItemIDList AbsoluteIdList = {read=GetAbsPidl};
  793.     __property Uptshell95::PItemIDList RelativeIdList = {read=mRelPidl};
  794.     __property Uptshell95::IShellFolder* ThisIShf = {read=GetThisIShf};
  795.     __property System::AnsiString PathName = {read=GetPathName};
  796.     __property bool Editable = {read=GetEditable, nodefault};
  797.     __property void * Data = {read=mData, write=mData};
  798. };
  799.  
  800. class PASCALIMPLEMENTATION TPTShListData : public System::TObject 
  801. {
  802.     typedef System::TObject inherited;
  803.     
  804. private:
  805.     TPTCustomShellList* mOwner;
  806.     Uptshell95::TItemIDList *mAbsPidl;
  807.     Uptshell95::TItemIDList *mRelPidl;
  808.     void *mData;
  809.     System::AnsiString mDisplayName;
  810.     bool mfDataValid;
  811.     System::AnsiString mSize;
  812.     System::AnsiString mType;
  813.     System::AnsiString mModified;
  814.     Uptshell95::PItemIDList __fastcall GetAbsoluteIdList(void);
  815.     int __fastcall GetAttributes(void);
  816.     bool __fastcall GetEditable(void);
  817.     System::AnsiString __fastcall GetDisplayName(void);
  818.     System::AnsiString __fastcall GetFilename(void);
  819.     System::AnsiString __fastcall GetPathName(void);
  820.     System::AnsiString __fastcall GetColText(int col);
  821.     void __fastcall GetExtraData(void);
  822.     System::AnsiString __fastcall GetSize(void);
  823.     System::AnsiString __fastcall GetFileType(void);
  824.     System::AnsiString __fastcall GetModified(void);
  825.     void __fastcall SetData(Uptshell95::PItemIDList aRelPidl);
  826.     
  827. public:
  828.     __fastcall TPTShListData(TPTCustomShellList* aOwner);
  829.     __fastcall virtual ~TPTShListData(void);
  830.     bool __fastcall IsFolder(void);
  831.     bool __fastcall IsLnkShortcut(void);
  832.     bool __fastcall IsValid(void);
  833.     bool __fastcall IsFileSystem(void);
  834.     void __fastcall Flush(void);
  835.     __property TPTCustomShellList* Owner = {read=mOwner};
  836.     __property Uptshell95::PItemIDList AbsoluteIdList = {read=GetAbsoluteIdList};
  837.     __property bool Editable = {read=GetEditable, nodefault};
  838.     __property Uptshell95::PItemIDList RelativeIdList = {read=mRelPidl};
  839.     __property int Attributes = {read=GetAttributes, nodefault};
  840.     __property System::AnsiString DisplayName = {read=GetDisplayName};
  841.     __property System::AnsiString FileName = {read=GetFilename};
  842.     __property System::AnsiString PathName = {read=GetPathName};
  843.     __property System::AnsiString ColText[int col] = {read=GetColText};
  844.     __property System::AnsiString Size = {read=GetSize};
  845.     __property System::AnsiString FileType = {read=GetFileType};
  846.     __property System::AnsiString Modified = {read=GetModified};
  847.     __property void * Data = {read=mData, write=mData};
  848. };
  849.  
  850. class PASCALIMPLEMENTATION TPTShComboData : public System::TObject 
  851. {
  852.     typedef System::TObject inherited;
  853.     
  854. private:
  855.     TPTCustomShellCombo* mOwner;
  856.     Uptshell95::IShellFolder* mishfParent;
  857.     Uptshell95::TItemIDList *mParentPidl;
  858.     Uptshell95::TItemIDList *mRelPidl;
  859.     Uptshell95::TItemIDList *mAbsPidl;
  860.     Uptshell95::IShellFolder* mThisIShf;
  861.     void *mData;
  862.     Uptshell95::IShellFolder* __fastcall GetThisIShf(void);
  863.     void __fastcall SetData(Uptshell95::IShellFolder* aParentIShf, Uptshell95::PItemIDList parentPidl, 
  864.         Uptshell95::PItemIDList curRelativePidl);
  865.     
  866. public:
  867.     __fastcall TPTShComboData(TPTCustomShellCombo* aOwner);
  868.     __fastcall virtual ~TPTShComboData(void);
  869.     __property Uptshell95::PItemIDList ParentIdList = {read=mParentPidl};
  870.     __property Uptshell95::IShellFolder* ParentIShf = {read=mishfParent};
  871.     __property Uptshell95::PItemIDList RelativeIdList = {read=mRelPidl};
  872.     __property Uptshell95::PItemIDList AbsoluteIdList = {read=mAbsPidl};
  873.     __property Uptshell95::IShellFolder* ThisIShf = {read=GetThisIShf};
  874.     __property void * Data = {read=mData, write=mData};
  875. };
  876.  
  877. //-- var, const, procedure ---------------------------------------------------
  878. #define PTSH_AM_CHANGE_NOTIFY (Word)(1125)
  879. #define PTSH_AM_DEFERRED_EDIT (Word)(1126)
  880. #define PTSH_AM_DEFERRED_FILL (Word)(1127)
  881. #define PTSH_AM_LAST (Word)(1174)
  882. extern PACKAGE int PTSH_CHANGE_NOTIFY_DELAY;
  883. extern PACKAGE int PTSH_CHANGE_NOTIFY_FASTDELAY;
  884. extern PACKAGE int PTSH_TREE_KEY_UPDATE_DELAY;
  885. extern PACKAGE int PTSH_MAX_FOLDER_ATTEMPTS;
  886. extern PACKAGE int PTSH_AUTOSCROLL_THRESHOLD_X;
  887. extern PACKAGE int PTSH_AUTOSCROLL_THRESHOLD_Y;
  888. extern PACKAGE int PTSH_AUTOSCROLL_MINDELAY_MS;
  889. extern PACKAGE Word CF_IDLIST;
  890. extern PACKAGE bool __fastcall PTShCreateNewFolder(System::AnsiString aPathname, System::AnsiString 
  891.     &aNewName);
  892.  
  893. }    /* namespace Uptshellcontrols */
  894. #if !defined(NO_IMPLICIT_NAMESPACE_USE)
  895. using namespace Uptshellcontrols;
  896. #endif
  897. //-- end unit ----------------------------------------------------------------
  898. #endif    // UPTShellControls
  899.